
downPage = function(){
	Ext.tip.QuickTipManager.init(); 
	//Ext.Msg.alert(teacherId);
	//Ext.Msg.alert("提示",teacherId);
	var teachId = downloadTeacherId;
	//Ext.Msg.alert("提示",teachId);
	Ext.define('fileModel',{
		extend:'Ext.data.Model',
		fields:[
		        	{name:'fileId',type:'String'},
			        {name:'fileName',type:'string'},
			        {name:'uploadTime',type:'string'},
			        {name:'downloadNumber',type:'int'}
			       ]
	});
	var fileStore = Ext.create('Ext.data.Store',{
		pageSize:2,
		model:fileModel,
		autoLoad:true,
		proxy:{
			type:'ajax',
			url:'getFileListByteachIdAction.action',
			reader:{
				type:'json',
				root:'fileList.list',
				totalProperty:'fileList.total'
			},
			extraParams:{
				teacherId : teachId
        	}
		
		}
	});
	var historyFile = Ext.create('Ext.grid.Panel',{
		store:fileStore,	
		columnLines:true,
		disableSelection:false,
		loadMask:true,
		anchor:'100%',
		columns:[
		         new Ext.grid.RowNumberer(),
		         {text:'编号',width:150,dataIndex:'fileId',sortable:true,hidden:true},
		         {text:'文件名',width:300,dataIndex:'fileName',sortable:true},
		         {text:"上传时间",width:300,dataIndex:'uploadTime',sortable:true, renderer : function(_registerDate){
		             return _registerDate.replace("T"," ").substring(0,16);
		         }},
		         {text:'下载次数',width:250,dataIndex:'downloadNumber',sortable:true},        
		         { 
		        	 header: '操作', 
		        	 xtype: 'actioncolumn', 
		        	 width: 100, 
		        	 items: ['->',{ 
		        	 iconCls: 'Arrowdown', 
		        	 tooltip: '下载', 
		        	 handler: function (grid, rowIndex, colIndex) { 
		        		 var rec = grid.getStore().getAt(rowIndex);
		        		 var fileId = rec.get('fileId');		       
		        		 window.location.href="downloadFileAction.action?fileId="+fileId;
		        	 	}
		        	 }
		        	 ]
		        	 }
		         ],
	
		title:"资料列表",
		loadMask:true,
		dockedItems:[
		     		{
		     			dock:'bottom',
		     			xtype:'pagingtoolbar',	
		     			store:fileStore,
		     			displayInfo:true,
		     			displayMsg:'显示{0}-{1}条，共计{2}条',
		     			emptyMsg:"没有数据"
		     		}]
	});
	
	
	return historyFile;
};